<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="/WEB-INF/views/modules/cms/front/include/taglib.jsp"%>
	<head>
		<title>高校大全</title>
		<meta name="decorator" content="cms_default_${site.theme}"/>
		<meta name="description" content="JeeSite ${site.description}"/>
		<meta name="keywords" content="JeeSite ${site.keywords}"/>
		<link rel="stylesheet" href="${ctxStatic}/css/main.css"/>
		<link rel="stylesheet" href="${ctxStatic}/css/style.css"/>
		<link rel="stylesheet" href="${ctxStatic}/css/pagination.css"/>
		<script type="text/javascript">
			function page(n,s){
				$("#pageNo").val(n);
				$("#pageSize").val(s);
				$("#searchForm").submit();
	        	return false;
	        }
			function choose(id,v){
				$("#"+id).val(v);
				$("#pageNo").val("1");
				$("#searchForm").submit();
				return false;
			}
		</script>
	</head>
	<body>
		<img src="${ctxStatic}/img/tit.png" class="img1"/>
		<div class="shop-center">
			<div class="sct">
				<label>首页</label>
				<span>></span>
				<label>选学校</label>
			</div>
			<div class="sct1">
				<h1>高校</h1>
				<div class="sct1-center">
					<h2>大全</h2>
					<span>你身边的报考专家</span>
					<label>COLLEGES AND UNIVERSITIES</label>
				</div>
			</div>
			<DIV class="sct2">
				<form id="searchForm" modelAttribute="university" action="${ctx}/university/complete.html" method="post">
					<input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
					<input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
					<input id="provinceIdList" name="provinceIdList" type="hidden" value="${university.provinceIds}">
					<input id="typeValList" name="typeValList" type="hidden" value="${university.typeVals}">
					<input id="levelValList" name="levelValList" type="hidden" value="${university.levelVals}">
					<input id="natureValList" name="natureValList" type="hidden" value="${university.natureVals}">
					<input id="subjectionValList" name="subjectionValList" type="hidden" value="${university.subjectionVals}">
					<input type="text" name="name" value="${university.name}" placeholder="请输入院校名称"/>
					<button type="submit"></button>
				<form>
			</DIV>
			<div class="sct3">
				<ul>
					<li>
						<div class="sct3-lt1"><label>院校所在地：</label></div>
						<div class="sct3-rt">
							<a style="text-decoration:none" href="javascript:choose('provinceIdList','')" 
								<c:if test="${university.provinceIdList == null || university.provinceIdList.size() < 1}">
									class="onsure"
								</c:if>>全国</a>
							<c:forEach items="${fns:getRegionList('2')}" var="province">
								<a style="text-decoration:none" 
									<c:if test="${university.provinceIdList != null && university.provinceIdList.size() > 0}">
										href="javascript:choose('provinceIdList','${province.id},${university.provinceIds}')" 
									</c:if>
									<c:if test="${university.provinceIdList == null || university.provinceIdList.size() < 1}">
										href="javascript:choose('provinceIdList','${province.id}')" 
									</c:if>
									<c:forEach items="${university.provinceIdList}" var="provinceId">
										<c:if test="${province.id.equals(provinceId)}">class="onsure"</c:if>
									</c:forEach>>
									${province.name}
								</a>
							</c:forEach>
						</div>
					</li>
					<li>
						<div class="sct3-lt"><label>院校类型：</label></div>
						<div class="sct3-rt">
							<a style="text-decoration:none" href="javascript:choose('typeValList','')" 
								<c:if test="${university.typeValList == null || university.typeValList.size() < 1}">
									class="onsure"
								</c:if>>不限</a>
							<c:forEach items="${fns:getDictList('university_type')}" var="universityType">
								<a style="text-decoration:none" 
									<c:if test="${university.typeValList != null && university.typeValList.size() > 0}">
										href="javascript:choose('typeValList','${universityType.value},${university.typeVals}')" 
									</c:if>
									<c:if test="${university.typeValList == null || university.typeValList.size() < 1}">
										href="javascript:choose('typeValList','${universityType.value}')" 
									</c:if>
									<c:forEach items="${university.typeValList}" var="typeVal">
										<c:if test="${universityType.value.equals(typeVal)}">class="onsure"</c:if>
									</c:forEach>>
									${universityType.label}
								</a>
							</c:forEach>
						</div>
					</li>
					<li>
						<div class="sct3-lt"><label>办学层次：</label></div>
						<div class="sct3-rt">
							<a style="text-decoration:none" href="javascript:choose('levelValList','')" 
								<c:if test="${university.levelValList == null || university.levelValList.size() < 1}">
									class="onsure"
								</c:if>>不限</a>
							<c:forEach items="${fns:getDictList('university_level')}" var="universityLevel">
								<a style="text-decoration:none" 
									<c:if test="${university.levelValList != null && university.levelValList.size() > 0}">
										href="javascript:choose('levelValList','${universityLevel.value},${university.levelVals}')" 
									</c:if>
									<c:if test="${university.levelValList == null || university.levelValList.size() < 1}">
										href="javascript:choose('levelValList','${universityLevel.value}')" 
									</c:if>
									<c:forEach items="${university.levelValList}" var="levelVal">
										<c:if test="${universityLevel.value.equals(levelVal)}">class="onsure"</c:if>
									</c:forEach>>
									${universityLevel.label}
								</a>
							</c:forEach>
						</div>
					</li>
					<li>
						<div class="sct3-lt"><label>办学性质：</label></div>
						<div class="sct3-rt">
							<a style="text-decoration:none" href="javascript:choose('natureValList','')" 
								<c:if test="${university.natureValList == null || university.natureValList.size() < 1}">
									class="onsure"
								</c:if>>不限</a>
							<c:forEach items="${fns:getDictList('university_nature')}" var="universityNature">
								<a style="text-decoration:none" 
									<c:if test="${university.natureValList != null && university.natureValList.size() > 0}">
										href="javascript:choose('natureValList','${universityNature.value},${university.natureVals}')" 
									</c:if>
									<c:if test="${university.natureValList == null || university.natureValList.size() < 1}">
										href="javascript:choose('natureValList','${universityNature.value}')" 
									</c:if>
									<c:forEach items="${university.natureValList}" var="natureVal">
										<c:if test="${universityNature.value.equals(natureVal)}">class="onsure"</c:if>
									</c:forEach>>
									${universityNature.label}
								</a>
							</c:forEach>
						</div>
					</li>
					<li>
						<div class="sct3-lt"><label>院校隶属：</label></div>
						<div class="sct3-rt">
							<a style="text-decoration:none" href="javascript:choose('subjectionValList','')" 
								<c:if test="${university.subjectionValList == null || university.subjectionValList.size() < 1}">
									class="onsure"
								</c:if>>不限</a>
							<c:forEach items="${fns:getDictList('subjection_type')}" var="subjectionType">
								<a style="text-decoration:none" 
									<c:if test="${university.subjectionValList != null && university.subjectionValList.size() > 0}">
										href="javascript:choose('subjectionValList','${subjectionType.value},${university.subjectionVals}')" 
									</c:if>
									<c:if test="${university.subjectionValList == null || university.subjectionValList.size() < 1}">
										href="javascript:choose('subjectionValList','${subjectionType.value}')" 
									</c:if>
									<c:forEach items="${university.subjectionValList}" var="subjectionVal">
										<c:if test="${subjectionType.value.equals(subjectionVal)}">class="onsure"</c:if>
									</c:forEach>>
									${subjectionType.label}
								</a>
							</c:forEach>
						</div>
					</li>
				</ul>
			</div>
			<ul class="sct4">
				<c:forEach items="${page.list}" var="university">
					<li>
						<div class="sct4-center">
							<div class="sct4-lt"><img src="${university.logo}"/></div>
							<div class="sct4-rt">
								<h1>${university.name}</h1>
								<p>
									<label>隶属：<span>${university.subjection.label}</span></label>
									<label>类型：<span>${university.type.label}</span></label>
									<label>城市：<span>${university.province.name}</span></label>
									<label>排名：<span>${university.ranking}</span></label>
								</p>
								<div class="sct4-tit">
									<span>985</span>
									<span>211</span>
									<span>自主</span>
									<span>研究生院</span>
								</div>
							</div>
						</div>
						<button type="button" onclick="javascript:window.location.href='${ctx}/university/intro-${university.id}.html'">查看详情</button>
					</li>
				</c:forEach>
			</ul>
			<div class="pagination">${page}</div>
		</div>
	</body>
